﻿

namespace Simple.Services
{
    public class LecturerInputModel : ModelBase
    {
        /// <summary>
        /// 主键
        /// </summary>
        public Guid? Id { get; set; }

        /// <summary>
        /// 讲师姓名
        /// </summary>
        [Required(ErrorMessage = "讲师姓名不能为空")]
        public string? Name { get; set; }

        /// <summary>
        /// 讲师分类
        /// </summary>
        [Required(ErrorMessage = "讲师分类不能为空")]
        public EnumLecturerType LecturerType { get; set; }

        /// <summary>
        /// 介绍
        /// </summary>
        [Required(ErrorMessage = "介绍不能为空")]
        public string? Description { get; set; }

        public override void ConfigureMapper(Profile profile)
        {
            profile.CreateMap<Lecturer, LecturerInputModel>();

            profile.CreateMap<LecturerInputModel, Lecturer>();

        }
    }
}
